package com.drug.mapper;

import com.drug.domain.DrugInformation;
import com.drug.domain.PurchaseOrder;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
@Mapper
public interface PurchaseOrderMapper {


    int insert(PurchaseOrder record);

    int insertSelective(PurchaseOrder record);

    PurchaseOrder selectByPrimaryKey(Integer poId);

    int updateByPrimaryKeySelective(PurchaseOrder record);

    int updateByPrimaryKey(PurchaseOrder record);

    List<PurchaseOrder> selectPurchaseOrder(PurchaseOrder purchaseOrder);

    int insetImp(PurchaseOrder purchaseOrder);

    int updateState(int id);

    List<PurchaseOrder> selectAll1();
 /**
     * ????????
     * @param
     * @return
     */
    void deleteByPrimaryKey(@Param("purchaseOrder") PurchaseOrder purchaseOrder);
	 /**
     * ?????????
     * @return
     */
    List<PurchaseOrder> selectAll(@Param("purchaseOrder") PurchaseOrder purchaseOrder, @Param("leftStr")String leftStr, @Param("rightStr")String rightStr);


    void addAll(@Param("purchaseOrder") PurchaseOrder purchaseOrder);

    List<PurchaseOrder> selectById(@Param("purchaseOrder") PurchaseOrder purchaseOrder);

    /**
     * ???????
     * @param purchaseOrder
     */
    void uptadelalala(@Param("purchaseOrder") PurchaseOrder purchaseOrder);
	
	
	    /**
     * ��������ѯ�ɹ�����ҳ
     * @param purchaseOrder
     * @return
     */
   List<PurchaseOrder> selectPurchaseOrder(@Param("purchaseOrder") PurchaseOrder purchaseOrder, @Param("leftTime") String leftTime, @Param("rightTime") String rightTime);

    //�޸�(�ύ��˽��)
    int updateSubmit(PurchaseOrder purchaseOrder);


    //根据采购单id查询医院id
    Integer selectyiyuanid(@Param("poid") Integer poid);
}